package com.kgc.scd.service;

import com.kgc.scd.bean.Coupon;
import com.kgc.scd.util.UserAnno;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * Created On : 2022/6/15.
 * <p>
 * Author     : 98730
 * <p>
 * Description: 远程调用优惠券接口
 */
@FeignClient(value = "blmall-server-ly-8103")
public interface PlaceOrderFeignService {

    /**
     * @author : 98730
     * @date   : 2022/6/15
     * @param  : [java.lang.String, java.lang.Integer]
     * @return : com.kgc.scd.bean.Coupon
     * @description : 校验优惠券是否可用（是否过期）
     */
    @PostMapping("/updateUserCouponIsLate")
    Coupon updateUserCouponIsLate(@RequestParam("userId") String userId, @RequestParam("innerId") Integer innerId);

    @PostMapping("/changeUserCouponStatus")
    boolean changeUserCouponStatus(@RequestParam("innerId") Integer innerId);
}
